﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using Citi.SecurityWebBrowser;
using Citi.SecurityHelper;
using EO.WebBrowser;

namespace Citi.Encryption
{
    public partial class TestBrowser : Form
    {
        public TestBrowser()
        {
            InitializeComponent();
        }

        private void TestBrowser_Load(object sender, EventArgs e)
        {
            webControl1.Height = Height;
            
            //webView1.BeforeDownload += webView1_BeforeDownload;
            var pearlUrl = "https://pearl.nj.ssmb.com/siteminderagent/forms/login.fcc?TYPE=33554433&REALMOID=06-fb51622c-add9-1001-9bdc-847a5366ff21&GUID=&SMAUTHREASON=0&METHOD=GET&SMAGENTNAME=-SM-TSXzCZBCWQfzzR6LEV6XtEMrota02ItSl0QgFPxXin03Wt9NJusCYSasBcT6zdoJT%2fuU6B%2b%2b02sSh2OVblMd8gXfnNQ9TyP9&TARGET=-SM-%2fpsp%2fplpfprg%2fEMPLOYEE%2fEPM%2fc%2fBCC_REPORTS_HOME%2eBCC_BO_R3_LINK%2eGBL%3fFolderPath%3dPORTAL_ROOT_OBJECT%2eBCC_COUNTRY_CORE%2eBCC_REPORTING%2eBCC_BO_R3_LINK_GBL%26IsFolder%3dfalse%26IgnoreParamTempl%3dFolderPath-%2cIsFolder";
            webControl1.LogSingleSignOn("LD41319", LoginType.Sso, pearlUrl);
        }

        void webView1_BeforeDownload(object sender, EO.WebBrowser.BeforeDownloadEventArgs e)
        {
            e.ShowDialog = false;
            
        }

       
    }
}
